package org.hawk.gwtppc.webtest.tests.constructorsuite;

import java.util.List;

import org.hawk.gwtppc.webtest.common.Asserts;
import org.hawk.gwtppc.webtest.common.Test;
import org.hawk.gwtppc.webtest.tests.mock.GenericClassMock;
import org.hawk.gwtppc.webtest.tests.mock.SubClassMock2;
import org.hawk.gwtppc.webtest.tests.mock.SubClassMock3;

public class IsVarArgsTest implements Test {

	public void run() throws Throwable {
		Asserts.assertFalse(SubClassMock2.class.getDeclaredConstructor(String.class).isVarArgs());
		Asserts.assertTrue(SubClassMock3.class.getDeclaredConstructor(String[].class).isVarArgs());
				
		Asserts.assertFalse(GenericClassMock.class.getDeclaredConstructor(List.class, CharSequence.class, 
				Object.class, Object.class).isVarArgs());
		Asserts.assertTrue(GenericClassMock.class.getDeclaredConstructor(List[].class).isVarArgs());
	}

	public String getName() {
		return "isVarArgs()";
	}

}
